package com.zzh.jetpackdemo

import androidx.appcompat.app.AppCompatActivity
import android.os.Bundle
import com.zzh.jetpackdemo.camera_x.CameraXActivity
import com.zzh.jetpackdemo.ctrip.CtripActivity
import com.zzh.jetpackdemo.room.RoomActivity
import com.zzh.jetpackdemo.extension.myStartActivity
import com.zzh.jetpackdemo.live.LiveActivity
import com.zzh.jetpackdemo.manager.ManagerActivity
import com.zzh.jetpackdemo.navigation.NavigationActivity
import com.zzh.jetpackdemo.paging.PagingActivity
import kotlinx.android.synthetic.main.activity_main.*

class MainActivity : AppCompatActivity() {
    override fun onCreate(savedInstanceState: Bundle?) {
        super.onCreate(savedInstanceState)
        setContentView(R.layout.activity_main)

        doom.setOnClickListener {
            myStartActivity(RoomActivity::class.java)
        }

        live.setOnClickListener {
            myStartActivity(LiveActivity::class.java)
        }

        manager.setOnClickListener {
            myStartActivity(ManagerActivity::class.java)
        }

        navigation.setOnClickListener {
            myStartActivity(NavigationActivity::class.java)
        }

        paging.setOnClickListener {
            myStartActivity(PagingActivity::class.java)
        }

        ctrip.setOnClickListener {
            myStartActivity(CtripActivity::class.java)
        }

        skipCameraX.setOnClickListener {
            myStartActivity(CameraXActivity::class.java)
        }

    }
}